// mock.js
import Mock from 'mockjs'
import axios from 'axios'
import MockAdapter from 'axios-mock-adapter'
import user_icon_1 from '../assets/avatar_1.png'
import user_icon_2 from '../assets/avatar_2.png'
import userImg from '../assets/avatar.png'

let mock = new MockAdapter(axios)

mock.onGet('/api/user').reply(200, {
  user: Mock.mock({
    userInfo: { userName: '翟枫君',userImg:userImg, contractedStatus: true, cardId: '1234567890123456', gender: '女', age: '26', phone: '12345678911', address: '广东省佛山市南海区大沥镇五一村3号', source: '医生建档', lable: [{ color: '#49b9ad', text: '高血压', bgColor: '#eafefa' }, { color: '#fca382', text: '低血糖', bgColor: '#fff2e8' }] },
    userFamilyMembers: [{memberName:'韦栋',age:'58',relationship:'母亲',gender:'女',img:user_icon_1},{memberName:'布馨昭',age:'60',relationship:'父亲',gender:'男',img:user_icon_2}],
  })
})